<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/5/17 0017
 * Time: 下午 5:03
 */

namespace App\Models;


use Illuminate\Database\Eloquent\Model;

class MessageTpl extends Model
{
    protected $table = 'message_tpl';

    protected $fillable = [
        'id',
        'name', //类型名
        'title', //标题
        'message', //系统消息内容
        'icon', //图标
        'admin_id', //添加人
        'push_message', //推送消息内容
        'system', //1发消息 0不发
        'push', //1发消息 0 不发
        'note', //1发送 0 不发
    ];

    public function admin()
    {
        return $this->hasOne('App\Models\Admin','id','admin_id');
    }

}